package com.ark.cloud.dataservices.modules.sys.entity.form;

import com.ark.cloud.dataservices.common.web.entity.form.BaseForm;
import com.ark.cloud.dataservices.modules.sys.entity.po.User;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import java.util.Set;

@Data
@EqualsAndHashCode(callSuper = true)
public class UserForm extends BaseForm<User> {

    @NotBlank(message = "用户名不能为空")
    private String username;

    @NotBlank(message = "用户密码不能为空")
    private String password;

//    @NotBlank(message = "用户手机号不能为空")
    private String mobile;

    private String phone;

    private String email;

    @NotBlank(message = "用户名称不能为空")
    private String name;

    private String description;

    private Set<String> roleIds;

    private Set<String> groupIds;

    private Set<String> positionIds;

    //账号是否可用 true为可用
    private Boolean enabled = true;

    //"用户账号是否过期，true为未过期"
    private Boolean accountNonExpired = true;

    //"用户密码是否过期，true为未过期"
    private Boolean credentialsNonExpired = true;

    //"用户账号是否被锁定，true为未锁定"
    private Boolean accountNonLocked = true;
}
